package cn.edu.ysu.zry.config;

import cn.edu.ysu.zry.entity.Xieyi;
import cn.edu.ysu.zry.entity.ZhongJiedian;
import cn.edu.ysu.zry.util.RSACoder;

import java.util.ArrayList;
import java.util.LinkedList;
import java.util.Map;

/**
 * @program: XieyiBlockChainOS
 * @description: 中心文件启动时的配置文件
 * @author: Ruiyuan Zhang
 * @create: 2020-04-20 11:16
 */
public class ConfigZhongxin {

    // 中心节点的公私钥
    public static Map<String,Object> keyMap = RSACoder.initKey();
    public static byte[] PUBLIC_KEY= RSACoder.getPublicKey(keyMap);
    public static byte[] PRIVATE_KEY=RSACoder.getPrivateKey(keyMap);

    // 重节点列表
    public static ArrayList<ZhongJiedian> zhongJiedianArrayList = new ArrayList<>();

    // 希望加入记账的重节点列表
    public static LinkedList<ZhongJiedian> applyZhongJiedianArrayList = new LinkedList<>();

    // 当前正在记账的重节点
    public static ZhongJiedian currentZhongJiedian;
}

